package com.itheima.test02;

import java.util.Scanner;

public class Demo_001 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        String s = n+"";
        StringBuilder sb = new StringBuilder(s);
        StringBuilder reverse = sb.reverse();
        String s1 = reverse.toString();
        int i = Integer.parseInt(s1);
        System.out.println(i);
    }
}
